﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using DomainModel;
using BL;

namespace SL
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "Service3" in code, svc and config file together.
    public class SLCustomer : ISLCustomer
    {

        public void InsertCustomer(BaseCustomer customer, ref List<string> errors)
        {
            BLCustomers.InsertCustomer(customer, ref errors);
        }
        public void BlockUser(int userID, ref List<string> errors)
        {
            BLCustomers.BlockUser(userID, ref errors);
        }
        public void UnBlockCustomer(int id, ref List<string> errors)
        {
            BLCustomers.UnBlockCustomer(id, ref errors);
        }
        public void ChangePermission(BaseCustomer customer, ref List<string> errors)
        {
            BLCustomers.ChangePermission(customer, ref errors);
        }
        public void UpdateUserReden(int id, BaseCustomer UpdateList, ref List<string> errors)
        {
            BLCustomers.UpdateUserReden(id, UpdateList, ref errors);
        }
      /*  public void UnBlockCustomer(int id, ref List<string> errors)
        {
            BLCustomers.UnBlockCustomer(id, ref errors);
        }*/
        public List<BaseCustomer> GetName(ref List<string> errors)
        {
            return BLCustomers.GetName(ref errors);
        }
        public BaseCustomer getId(BaseCustomer customer, ref List<string> errors)
        {
            return BLCustomers.getId(customer, ref errors);
        }
        public String GetEmail(int id, ref List<string> errors)
        {
            return BLCustomers.GetEmail(id, ref errors);
        }
        public BaseCustomer GetCustomerDetail(int id, ref List<string> errors)
        {
            return BLCustomers.GetCustomerDetail(id, ref errors);
        }
        public void DeleteCustomer(int id, ref List<string> errors)
        {
            BLCustomers.DeleteCustomer(id, ref errors);
        }
        public BaseCustomer LoginInCheck(String email , String firstname , ref List<string> errors) 
        {
            return BLCustomers.LoginInCheck(email , firstname , ref errors);
        }


        public  int GetTotalUser(ref List<string> errors)
        {
            return BLCustomers.GetTotalUser(ref errors);
        }

        public  int GetTotalWebMaster(ref List<string> errors)
        {
            return BLCustomers.GetTotalWebMaster(ref errors);
        }

        public  int GetTotalBlock(ref List<string> errors)
        {
            return BLCustomers.GetTotalBlock(ref errors);
        }
        public  List<BaseCustomer> GetBlockUserInfor(ref List<string> errors)
        {
            return BLCustomers.GetBlockUserInfor(ref errors);
        }

        public  List<BaseCustomer> GetWebMasterInfor(ref List<string> errors)
        {
            return BLCustomers.GetWebMasterInfor(ref errors);
        }

        public int IdfromEmail(string email, ref List<string> errors)
        {
            return BLCustomers.GetIdFromEmail(email, ref errors);
        }

    }
}
